package com.brook.app.android.filepicker.core;

import android.content.Context;
import androidx.annotation.NonNull;

import java.util.Set;

/**
 * @author Brook
 * @time 2020-03-14 10:56
 */
public class VideoPickerConfig extends FilePickerConfig implements Cloneable {

    private long mVideoDuration;

    public VideoPickerConfig() {
        super();
        addFileProvider(new VideoProvider());
        setPickerMimeType(MimeType.VIDEO.toString());
    }

    public long getVideoDuration() {
        return mVideoDuration;
    }

    public VideoPickerConfig setVideoMaxDuration(long second) {
        this.mVideoDuration = second;
        return this;
    }

    @Override
    public VideoPickerConfig setFileProviders(Set<IFileProvider> providers) {
        super.setFileProviders(providers);
        return this;
    }

    @Override
    public VideoPickerConfig setFileSize(long kb) {
        super.setFileSize(kb);
        return this;
    }

    @Override
    public VideoPickerConfig setPickCount(int pickCount) {
        super.setPickCount(pickCount);
        return this;
    }

    @Override
    public VideoPickerConfig setPickerMimeType(String type) {
        super.setPickerMimeType(type);
        return this;
    }

    @Override
    public VideoPickerConfig setApplicationContext(@NonNull Context mContext) {
        super.setApplicationContext(mContext);
        return this;
    }

    @Override
    public VideoPickerConfig setImageLoader(IThumbnailLoader imageLoader) {
        super.setImageLoader(imageLoader);
        return this;
    }

    @Override
    public VideoPickerConfig setStartPickerUIDelegate(IStartPickerUIDelegate startPickerUIDelegate) {
        super.setStartPickerUIDelegate(startPickerUIDelegate);
        return this;
    }

    @Override
    public VideoPickerConfig setCallback(FilePickCallback callback) {
        super.setCallback(callback);
        return this;
    }

    @NonNull
    @Override
    public VideoPickerConfig clone() throws CloneNotSupportedException {
        return (VideoPickerConfig) super.clone();
    }
}